﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace KinectWindowLib.Graphics
{
    // This Sores all the OpenGL and VTK Attribute to render a full Drawables on the Screen Object
    public class GraphicContext
    {
        public Screen Screen { get { return screen; } }
        private Screen screen;
        private NuiCanvas Canvase;
        /// <summary>
        /// Create the full GraphicContext
        /// </summary>
        /// <param name="screen">The Screen Object that the Context belong To</param>
        public virtual void CreateGC(Screen screen)
        {
            this.screen = screen;
            InitalizeGC();
        }
        /// <summary>
        /// Distroy the Graphic Context
        /// </summary>
        public void DistroyGC() { }
        /// <summary>
        /// Refresh the Graphic Context by Redrawing 
        /// </summary>
        public void RefreshGC() { }

        /// <summary>
        /// Initalise The Grafic Context
        /// </summary>
        public void InitalizeGC()
        {
            Canvase = new NuiCanvas();
            Canvase.GL = screen.Display.gl;
        }


        


    }

    /// <summary>
    /// Initalise The Display Canvas, Display class can use it
    /// </summary>
    public class NuiCanvas
    {
        public double Width { get; set; }
        public double Height { get; set; }
       
        public NuiCanvas()
        {
            // TODO: Complete member initialization
           
        }
      
        // Prepear thedisplay Object and initalise

        public void DrawLine(float x1, float y1, float x2, float y2)
        {
        }



        public void DrawRectangle(float x, float y, float width, float height)
        {
        }

        public void DrawCircule(float x, float y, float rad)
        {
        }

        public void DrawCircule(float x, float y, float rad, float startAngle, float endAngle)
        {
        }

          public void DrawImage(Byte[] row, int width, int height)
          {
          }




          public SharpGL.OpenGL GL { get; set; }
    }
}
